<!DOCTYPE html>
<html>

<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
  <title>layout 后台大布局 - Layui</title>
  <link rel="stylesheet" href="./assets/lib/layui/css/layui.css">
  <link rel="stylesheet" href="./assets/fonts/iconfont.css">
  <link rel="stylesheet" href="./assets/lib/nprogress/nprogress.css">
  <link rel="stylesheet" href="./assets/css/index.css">
  <script type="text/javascript">
    // 判断用户是否已经登录，如果没有登录，需要跳转到登录页面
    var token = sessionStorage.getItem('mytoken')
    if (!token) {
      // token不存在，跳转到登录页面
      location.href = './login.html'
    }
  </script>
</head>

<body class="layui-layout-body">
  <div class="layui-layout layui-layout-admin">
    <!-- 顶部导航栏 -->
    <div class="layui-header">
      <div class="layui-logo">
        <img src="./assets/images/logo.png">
      </div>
      <ul class="layui-nav layui-layout-right">
        <li class="layui-nav-item">
          <a href="javascript:;" class="nav-user">
            <!-- <img src="http://t.cn/RCzsdCq" class="layui-nav-img"> -->
            <div class="avatar">L</div>
            <span class="uinfo">黑马</span>
          </a>
          <dl class="layui-nav-child">
            <dd><a target="iframeArea" href="./my/base-info.html">基本资料</a></dd>
            <dd><a target="iframeArea" href="./my/replace.html">更换头像</a></dd>
            <dd><a target="iframeArea" href="./my/reset-pwd.html">重置密码</a></dd>
          </dl>
        </li>
        <li class="layui-nav-item"><a id="logout" href="javascript:;"><i
              class="layui-icon layui-icon-logout"></i>&nbsp;&nbsp;退了</a></li>
      </ul>
    </div>
    <!-- 左侧菜单栏 -->
    <div class="layui-side layui-bg-black">
      <div class="layui-side-scroll">
        <a href="javascript:;" class="welcome">
          <!-- <img src="http://t.cn/RCzsdCq" class="layui-nav-img"> -->
          <div class="avatar">L</div>
          <span class="ainfo">欢迎 XXX </span>
        </a>
        <!-- 左侧导航区域（可配合layui已有的垂直导航） -->
        <ul class="layui-nav layui-nav-tree" lay-shrink='all' lay-filter="test">
          <li class="layui-nav-item layui-this"><a href=""><span class="iconfont icon-home"></span>主页</a></li>
          <li class="layui-nav-item layui-nav-itemed">
            <a class="" href="javascript:;"><span class="iconfont icon-16"></span>文章管理</a>
            <dl class="layui-nav-child">
              <dd><a target="iframeArea" href="./article/cate.html"><i class="layui-icon layui-icon-app"></i>文章类别</a>
              </dd>
              <dd><a target="iframeArea" href="./article/list.html"><i class="layui-icon layui-icon-app"></i>文章列表</a>
              </dd>
              <dd><a target="iframeArea" href="./article/add.html"><i class="layui-icon layui-icon-app"></i>发表文章</a>
              </dd>
            </dl>
          </li>
          <li class="layui-nav-item">
            <a href="javascript:;"><span class="iconfont icon-user"></span>个人中心</a>
            <dl class="layui-nav-child">
              <dd><a target="iframeArea" href="./my/base-info.html"><i class="layui-icon layui-icon-app"></i>基本资料</a>
              </dd>
              <dd><a target="iframeArea" href="./my/replace.html"><i class="layui-icon layui-icon-app"></i>更换头像</a></dd>
              <dd><a target="iframeArea" href="./my/reset-pwd.html"><i class="layui-icon layui-icon-app"></i>重置密码</a>
              </dd>
            </dl>
          </li>
        </ul>
      </div>
    </div>
    <!-- 右侧内容区 -->
    <div class="layui-body">
      <!-- 内容主体区域 -->
      <iframe src="./home/dashboard.html" name="iframeArea"></iframe>
    </div>
    <!-- 底部的版权区域 -->
    <div class="layui-footer">
      <!-- 底部固定区域 -->
      © www.itheima.com - 黑马程序员
    </div>
  </div>
  <script src="./assets/lib/jquery.js"></script>
  <script src="./assets/lib/layui/layui.all.js"></script>
  <script src="./assets/lib/nprogress/nprogress.js"></script>
  <script src="./assets/js/common.js"></script>
  <script src="./assets/js/index.js"></script>
</body>

</html>